package com.sirap.spring.boot.demo.config;

import com.sirap.basic.component.Konstants;
import com.sirap.basic.component.map.AlinkMap;
import com.sirap.basic.tool.D;
import com.sirap.basic.util.Amaps;
import com.sirap.basic.util.IOUtil;
import com.sirap.common.framework.SimpleKonfig;

public class FishKonfig {

	public static final String PATH_AKA10 = System.getProperty("config.aka10");
	public static final String PATH_POI = System.getProperty("config.poi");

	static {
		String params = aka10Props().get("sirap.params");
		D.pla("noggin", PATH_AKA10, PATH_POI);
		SimpleKonfig.init(params);
		SimpleKonfig.g().setFromWeb(true);
	}
	
	public static AlinkMap<String, String> aka10Props() {
		AlinkMap<String, String> props = Amaps.ofProperties(IOUtil.readLines(PATH_AKA10, Konstants.CODE_UTF8));
		return props;
	}
	
	public static String storage() {
		return aka10Props().getX("file.upload.storage");
		
	}
}